// user
package member

import (
	"encoding/xml"
	"time"

	"awfan.cn/utils"
	"gopkg.in/mgo.v2/bson"
)

type MEMBERS_XML struct {
	XMLName xml.Name `xml:"members" json:"-"`

	Members []MEMBER_XML `xml:"member" json:"members"`
}

type MEMBER_XML struct {
	XMLName  xml.Name      `xml:"member" json:"-" bson:"-"`
	Id       bson.ObjectId `xml:"id" json:"id" bson:"_id,omitempty"`
	Name     string        `xml:"name" json:"name" bson:"name,omitempty"`
	Password string        `xml:"password" json:"password" bson:"password,omitempty"`

	Token        string                `xml:"token" json:"token" bson:"token,omitempty"`
	Mobile       string                `xml:"mobile" json:"mobile" bson:"mobile,omitempty"`
	Parent       utils.EMBED_DISPLAYID `xml:"parent" json:"parent" bson:"parent,omitempty"`
	School       utils.EMBED_DISPLAYID `xml:"school" json:"school" bson:"school,omitempty"`
	Mail         string                `xml:"mail" json:"mail" bson:"mail,omitempty"`
	Ip           string                `xml:"ip" json:"ip" bson:"ip,omitempty"`
	Role         string                `xml:"role" json:"role" bson:"role,omitempty"`
	Image        string                `xml:"image" json:"image" bson:"image,omitempty"`
	Address      string                `xml:"address" json:"address" bson:"address,omitempty"`
	Identity     string                `xml:"identity" json:"identity" bson:"identity,omitempty"`
	Created_time time.Time             `xml:"created_time" json:"created_time" bson:"created_time,omitempty"`
}
